<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>方法2：使用SVG掩码（Masking）</title>

    <style>
        body {
            background: blue;
        }

        .div-hole {
            width: 200px;
            height: 200px;
            background-color: red;
            mask: url('./test.svg');
        }
    </style>

</head>

<body>
    <div class="div-hole">内容</div>

</body>

</html>